#ifndef QDATABASEMANAGER_H
#define QDATABASEMANAGER_H

#include "../sharedlibglobal.h"

#include <QObject>
#include <QMap>

class QConfigDataBase;
class QHistoryDataBase;
class QLogDatabase;

struct tagDataInfo;

class SHAREDLIB_EXPORT QDataBaseManager : public QObject
{
    Q_OBJECT
public:
    explicit QDataBaseManager(QObject *parent = 0);
    ~QDataBaseManager();

    void    load(const QString &project_path);

    QMap<QString,QString>   get_hold_data();
    void                    set_hold_data(const QString &uuid,const QVariant &value);

    void                    save_data(tagDataInfo *info,const QString &time);

    void                    set_project_property(const QString &key,const QString &value);

    void                    add_log(const QString &time, const QString &user, const QString &tag, const QString &msg);
signals:
    
public slots:
protected:
    QConfigDataBase     *m_config_database;
    QHistoryDataBase    *m_history_database;
    QLogDatabase        *m_log_database;
};

#endif // QDATABASEMANAGER_H
